﻿using System;

namespace NuSoft.SistemaGestionPersonal.WinFormsUI.BusinessEntities
{
    public class Employee
    {        
        public int Id { get; set; }
        public DateTime EntryDate { get; set; }
        public string FirstName { get; set; }
        public string MiddleName { get; set; }
        public string FirstSurname { get; set; }
        public string SecondSurname { get; set; }
        public string DocumentType { get; set; }
        public string DocumentNumber { get; set; }
        public DateTime BirthDate { get; set; }
        public MaritalStatus MaritalStatus { get; set; }
        public Position Position { get; set; }
        public string FirstContactFirstName { get; set; }
        public string FirstContactSurname { get; set; }
        public string FirstContactTelephoneNumber { get; set; }
        public string FirstContactRelationship { get; set; }

        public override bool Equals(object obj)
        {
            bool result = false;

            Employee employee = obj as Employee;
            if (employee != null)
            {
                result = employee.Id == Id;
            }

            return result;
        }

        public override int GetHashCode()
        {
            return Id;
        }
    }
}